export default class AdminModal {
    title?: string;
    render: boolean;
    visible: boolean;
    modalData?: any;
    
    constructor() {
        this.render = false;
        this.visible = false;
    }

    show() {
        if (!this.render) {
            this.render = true;
        }
        this.visible = true;
        return this;
    }

    hide() {
        this.visible = false;
        return this;
    }

    setModalData(modalData: any) {
        this.modalData = modalData;
        return this;
    }

    setTitle(title: string) {
        this.title = title;
        return this;
    }
}